package com.aliang.book_java1.po.枚举;

public class Main {
    public static void main(String[] args) {
        /*Color red = Color.RED;
        System.out.println("The hex code for red is: " + red.getHexCode());*/

        /*Day today = Day.MONDAY;
        switch (today) {
            case MONDAY:
                System.out.println("Today is Monday.");
                break;
            case TUESDAY:
                System.out.println("Today is Tuesday.");
                break;
            // ... 其他情况的处理
            default:
                System.out.println("It's not a weekday.");
        }*/
        String str="sign,airModel,ccxlh,proctionDate,useDate,engine,maxZl,jl,nature,czr,startTime,endTime,zq,isTqtz,isWyyzdxz,zjbz,mqzj,gjNo,gjDate,bzfj,haveName,haveAddr,shNo,qfDate,hjNo,addrNoHex,addrNoOct,dtNo,dtbfDate,dtyxDate,dtzzjkbjrq,bz,yyfxxs,lyl,dxkssjQ,zjycdxrwmc,jhdxxyckssjT,jhxrwmc,tzsfdjxlh1,fdjzt1,tzsfdjxlh2,fdjzt2";
        String[] strArr=str.split(",");
        System.out.println("-----长度----"+strArr.length);
        StringBuilder code=new StringBuilder();
        for(int i=0;i<strArr.length;i++){
            code.append("lastRow.createCell(")
                    .append(i)
                    .append(").setCellValue(jsonObject.getString(\"").append(strArr[i]).append("\")); \n");
        }
        System.out.println(code.toString());
    }
}

enum Color {
    RED("FF0000"),
    GREEN("00FF00"),
    BLUE("0000FF");

    private final String hexCode;

    // 私有构造函数，用于初始化枚举常量
    Color(String hexCode) {
        this.hexCode = hexCode;
    }

    // 获取十六进制颜色代码的方法
    public String getHexCode() {
        return hexCode;
    }
}
//一周七天
enum Day {
    SUNDAY,
    MONDAY,
    TUESDAY,
    WEDNESDAY,
    THURSDAY,
    FRIDAY,
    SATURDAY
}
